package iedcyt.acute.controller;

import org.eclipse.swt.widgets.Listener;
import iedcyt.acute.controller.listeners.maesorgPublication.*;
import iedcyt.acute.model.MaesorgPublicationModel;
import iedcyt.acute.view.MaesorgPublicationView;

public class MaesorgPublicationController {

	private MaesorgPublicationView _view;
	private MaesorgPublicationModel _model;
	
	public MaesorgPublicationController(MaesorgPublicationView view){
		_view = view;
		_model = new MaesorgPublicationModel();
	}
	
	public void iniView() {
		_view.loadPublication(_model.getPublications());
	}
	
	public Listener getCandidatesKeyDownListener() {
		return new CandidatesKeyDownListener(_view, _model);
	}
	
	public Listener getPubsJsssKeyDownListener() {
		return new PubsJsssKeyDownListener(_view, _model);
	}
	
	public Listener getCandidatesSelectionListener() {
		return new CandidatesSelectionListener(_view, _model);
	}
	
	public Listener getPublicationKeyDownListener() {
		return new PublicationKeyDownListener(_view, _model);
	}
	
	public Listener getPublicationSelectionListener() {
		return new PublicationSelectionListener(_view, _model);
	}

}
